package org.rebluh.hulunbuirtravelnetworkbackendframework.controller;

import org.rebluh.hulunbuirtravelnetworkbackendframework.domain.Panorama;
import org.rebluh.hulunbuirtravelnetworkbackendframework.service.PanoramaService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;

@RestController
@RequestMapping("/panorama")
public class PanoramaController {
    @Autowired
    private PanoramaService panoramaService;

    @GetMapping
    public List<Panorama> getAllPanoramas() {
        return panoramaService.getAllPanorama();
    }

    @PostMapping
    public List<Panorama> getPanoramaByToHulberId(@RequestParam String id) {
        return panoramaService.getPanoramaByToHulberId(id);
    }
}
